<template>
  <div>
    <el-menu
        :default-active="activePath"
        class="sidebar-menu"
        background-color="#f6f7fb"
        text-color="#000000"
        active-text-color="#409eff"
    >
      <el-menu-item index="/home">
        <router-link to="/home" style="text-decoration: none; display: flex; align-items: center; padding: 0;">
          <i class="el-icon-s-home" style="margin-left: 10px;"></i>
          <span>首页</span>
        </router-link>
      </el-menu-item>
      <el-submenu index="/system">
        <template #title>
          <i class="el-icon-s-tools" ></i>
          <span style="margin-right: 80px;">用户管理</span>
        </template>
        <el-menu-item index="/system/user">
          <router-link to="/system/user" style="text-decoration: none; display: flex; align-items: center; padding: 0;">
            <i class="el-icon-user" style="margin-right: 10px;"></i>
            <span>用户管理</span>
          </router-link>
        </el-menu-item>
        <el-menu-item index="/system/team">
          <router-link to="/system/team" style="text-decoration: none; display: flex; align-items: center; padding: 0;">
            <i class="el-icon-s-grid" style="margin-right: 10px;"></i>
            <span>批次管理</span>
          </router-link>
        </el-menu-item>
        <el-menu-item index="/system/testPer">
          <router-link to="/system/testPer" style="text-decoration: none; display: flex; align-items: center; padding: 0;">
            <i class="el-icon-s-custom" style="margin-right: 10px;"></i>
            <span>参测人员管理</span>
          </router-link>
        </el-menu-item>
      </el-submenu>
      <el-submenu index="/assess">
        <template #title>
          <i class="el-icon-apple" ></i>
          <span style="margin-right: 80px;">评估管理</span>
        </template>
        <el-menu-item index="/assess/topic">
          <router-link to="/assess/topic" style="text-decoration: none; display: flex; align-items: center; padding: 0;">
            <i class="el-icon-sugar" style="margin-right: 10px;"></i>
            <span>题目管理</span>
          </router-link>
        </el-menu-item>

      </el-submenu>
      <el-menu-item index="/updatePw">
        <router-link to="/updatePw" style="text-decoration: none; display: flex; align-items: center; padding: 0;">
          <i class="el-icon-key" style="margin-left: 5px;"></i>
          <span>修改密码</span>
        </router-link>
      </el-menu-item>
    </el-menu>
  </div>
</template>

<script>
export default {
  computed: {
    activePath() {
      return this.$route.path;
    },
  },
};
</script>

<style scoped>

</style>
